package com.jdbc.entity;

/**
 * @author wzm
 * @create 2023-02-22 14:18
 */

/**
 * 学生的实体类 用于存储数据库中读取过来的信息
 * 数据库的表   ==   类
 * 数据库中的字段   ==  类的属性
 * 数据库中的一行 记录  ==  类的一个对象
 */
public class Student {
    private Integer id;
    private String stuName;
    private String stuSex;
    private  Integer age;
    private String address;
    private int status;

    //构造方法  get set toString


    public Student() {
    }

    public Student(Integer id, String stuName, String stuSex, Integer age, String address, int status) {
        this.id = id;
        this.stuName = stuName;
        this.stuSex = stuSex;
        this.age = age;
        this.address = address;
        this.status = status;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getStuName() {
        return stuName;
    }

    public void setStuName(String stuName) {
        this.stuName = stuName;
    }

    public String getStuSex() {
        return stuSex;
    }

    public void setStuSex(String stuSex) {
        this.stuSex = stuSex;
    }

    public Integer getAge() {
        return age;
    }

    public void setAge(Integer age) {
        this.age = age;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }

    @Override
    public String toString() {
        return "Student{" +
                "id=" + id +
                ", stuName='" + stuName + '\'' +
                ", stuSex='" + stuSex + '\'' +
                ", age=" + age +
                ", address='" + address + '\'' +
                ", status=" + status +
                '}';
    }
}
